#ifndef __CMD_HANDLER__
#define __CMD_HANDLER__

#include "msgHandler.h"
#include "dirStack.h"

typedef enum {
    CD,
    LS,
    PWD,
    PUTS,
    GETS,
    RM,
    RMDIR,
    MKDIR
} CmdType;

typedef struct cmd_s {
    char cmd[256];
    char args[1024];
} cmd_t;

int handleCmd(const int netfd, const train_t *pTrain, dirStack_t *pStack, MYSQL *connect, char *username);

#endif
